import { Module } from '@nestjs/common';
import { CaptchaController } from './captcha/captcha.controller';
import { APP_FILTER } from '@nestjs/core';
import { ValidationExceptionFilter } from 'src/filter/interface.filter';
import { FileController } from './file/file.controller';
import { UploadController } from './upload/upload.controller';
import { dictModule } from './dict/dict.module';
import { PrismaService } from '../../prisma/prisma.server';

@Module({
  imports: [dictModule],
  providers: [
    {
      provide: APP_FILTER,
      useClass: ValidationExceptionFilter,
    },
    PrismaService,
  ],
  controllers: [CaptchaController, FileController, UploadController],
})
export class CommonModule {}
